﻿<phone:PhoneApplicationPage 
    x:Class="KinectoPhone.Phone.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="768"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    SupportedOrientations="Portrait" Orientation="Portrait"
    shell:SystemTray.IsVisible="True"
    x:Name="GameWindow">
	<phone:PhoneApplicationPage.Resources>
		<Storyboard x:Name="sbWin">

			<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.TranslateX)" Storyboard.TargetName="winWall">
				<EasingDoubleKeyFrame KeyTime="0" Value="0"/>
				<EasingDoubleKeyFrame KeyTime="0:0:0.8" Value="-170">
					<EasingDoubleKeyFrame.EasingFunction>
						<QuadraticEase EasingMode="EaseIn"/>
					</EasingDoubleKeyFrame.EasingFunction>
				</EasingDoubleKeyFrame>
			</DoubleAnimationUsingKeyFrames>

		</Storyboard>
	</phone:PhoneApplicationPage.Resources>

    <!--LayoutRoot is the root grid where all page content is placed-->
    <Canvas x:Name="LayoutRoot" >
        <Canvas.Background>
            <ImageBrush ImageSource="/Images/grid.png"></ImageBrush>
        </Canvas.Background>

        <Canvas x:Name="player" Canvas.Left="0" Canvas.Top="0" Height="160" Width="160">
            <Image x:Name="triangle" Canvas.Left="0" Canvas.Top="0" Height="160" Width="160" Source="/Images/triangle.png">
                
            </Image>
            <Image x:Name="triangleHop" Opacity="0" Canvas.Left="0" Canvas.Top="0" Height="160" Width="160" Source="/Images/triangle_hop.png">
            </Image>
            <Canvas.RenderTransform>
                <TransformGroup>
                    <RotateTransform CenterX="80" CenterY="80" x:Name="playerRotation" Angle="0"></RotateTransform>
                </TransformGroup>
            </Canvas.RenderTransform>
        </Canvas>

        <Image x:Name="winWall" Visibility="Collapsed" Height="190" Canvas.Left="64" Source="Images/winWall.png" Stretch="Fill" Canvas.Top="367" Width="40" RenderTransformOrigin="0.5,0.5" UseLayoutRounding="False" d:LayoutRounding="Auto">
        	<Image.RenderTransform>
        		<CompositeTransform Rotation="90"/>
        	</Image.RenderTransform>
        </Image>
    </Canvas>
</phone:PhoneApplicationPage>